//
//  TMUserManager.h
//  国学商家管理
//
//  Created by mac on 2018/6/19.
//  Copyright © 2018年 mac. All rights reserved.
//

#import <Foundation/Foundation.h>
typedef void (^successBlock)(id);
@class TMUserModel;
@interface TMUserManager : NSObject
@property (nonatomic, strong) TMUserModel *userModel;
@property (nonatomic, assign, readonly) BOOL hasLogin;
@property (nonatomic, copy) successBlock block;
+(TMUserManager *)deaufatManager;
- (TMUserModel *)userModel;
+ (BOOL)hasLogin;
+ (void)autoLogin;
+ (void)logoutSuccessed:(successBlock)success;
- (void)updateUserModel:(TMUserModel *)user;
+ (void)loginWithUserName:(NSString *)userName password:(NSString *)password successed:(successBlock)success;
+ (void)loginWithPhone:(NSString *)userName code:(NSString *)password successed:(successBlock)success;
+ (void)registerWithDictionary:(NSDictionary *)dic Success:(successBlock)block;
+ (void)findPasswordWithDictionary:(NSDictionary *)dic Success:(successBlock)block;
+ (void)changePasswordWithDictionary:(NSDictionary *)dic Success:(successBlock)block;
+ (void)verificationCodeSendWithDictionary:(NSString*)phone;
+ (void)changeUserIcon:(UIImage *)image Success:(successBlock)block;
+ (void)uploadImageAndMovieBaseModel:(NSString *)paths Success:(successBlock)block;

//微信登录
+ (void)loginWithWecatWith:(NSDictionary *)dic Successed:(successBlock)success;
+ (void)blindPhoneWith:(NSDictionary *)dic Successed:(successBlock)success;
+(NSMutableDictionary *)paramDisplay;
+ (void)displayRCConfings;
+ (NSString *) pathForCacheObj:(id)obj ToLoaclPath:(NSString *) path;
+ (id) objFromPath:(NSString *) path;
@end
